package com.rc.saas.tenant.model.order;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.rc.saas.tenant.base.BaseModel;
import com.rc.saas.tenant.model.converter.AuditsStatusConverter;
import com.rc.saas.tenant.model.converter.PaymentTypeConverter;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.util.Date;

public class OrderRefundApply extends BaseModel {

    @ExcelIgnore
    private Long orderRefundApplyId;
    @ExcelIgnore
    private String tenantCode;

    @ExcelIgnore
    private Long memberId;

    @ExcelProperty(value = "退款申请单号",index = 3)
    private Long orderId;

    @ExcelProperty(value = "退款申请金额",index = 4)
    private BigDecimal amount;

    @ExcelProperty(value = "状态",index = 5, converter = AuditsStatusConverter.class)
    private String status;

    @ExcelProperty(value = "退款原因",index = 6)
    private String refundReason;

    @ExcelIgnore
    private String remark;
    @ExcelIgnore
    private String refundImg;
    @ExcelIgnore
    private String createdBy;

    @ExcelProperty(value = "退款申请时间",index = 7)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createdTime;

    @ExcelIgnore
    private String lastUpdatedBy;

    @ExcelIgnore
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date lastUpdatedTime;

    @ExcelIgnore
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date auditingTime;

    @ExcelProperty(value = "实际退款时间",index = 8)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date refundTime;

    @ExcelProperty(value = "实际退款金额",index = 9)
    private BigDecimal factAmount;

    @ExcelProperty(value = "退款途径",index = 10, converter = PaymentTypeConverter.class)
    private String paymentType;

    @ExcelProperty(value = "资金流水单号",index = 11)
    private String orderNum;

    @ExcelIgnore
    private BigDecimal beforeAccount;

    @ExcelIgnore
    private BigDecimal afterAccount;

    public Long getOrderRefundApplyId() {
        return orderRefundApplyId;
    }

    public void setOrderRefundApplyId(Long orderRefundApplyId) {
        this.orderRefundApplyId = orderRefundApplyId;
    }

    public String getTenantCode() {
        return tenantCode;
    }

    public void setTenantCode(String tenantCode) {
        this.tenantCode = tenantCode;
    }

    public Long getMemberId() {
        return memberId;
    }

    public void setMemberId(Long memberId) {
        this.memberId = memberId;
    }

    public Long getOrderId() {
        return orderId;
    }

    public void setOrderId(Long orderId) {
        this.orderId = orderId;
    }

    public BigDecimal getAmount() {
        return amount;
    }

    public void setAmount(BigDecimal amount) {
        this.amount = amount;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getRefundReason() {
        return refundReason;
    }

    public void setRefundReason(String refundReason) {
        this.refundReason = refundReason;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public String getRefundImg() {
        return refundImg;
    }

    public void setRefundImg(String refundImg) {
        this.refundImg = refundImg;
    }

    public String getCreatedBy() {
        return createdBy;
    }

    public void setCreatedBy(String createdBy) {
        this.createdBy = createdBy;
    }

    public Date getCreatedTime() {
        return createdTime;
    }

    public void setCreatedTime(Date createdTime) {
        this.createdTime = createdTime;
    }

    public String getLastUpdatedBy() {
        return lastUpdatedBy;
    }

    public void setLastUpdatedBy(String lastUpdatedBy) {
        this.lastUpdatedBy = lastUpdatedBy;
    }

    public Date getLastUpdatedTime() {
        return lastUpdatedTime;
    }

    public void setLastUpdatedTime(Date lastUpdatedTime) {
        this.lastUpdatedTime = lastUpdatedTime;
    }

    public Date getAuditingTime() {
        return auditingTime;
    }

    public void setAuditingTime(Date auditingTime) {
        this.auditingTime = auditingTime;
    }

    public Date getRefundTime() {
        return refundTime;
    }

    public void setRefundTime(Date refundTime) {
        this.refundTime = refundTime;
    }

    public BigDecimal getFactAmount() {
        return factAmount;
    }

    public void setFactAmount(BigDecimal factAmount) {
        this.factAmount = factAmount;
    }

    public String getPaymentType() {
        return paymentType;
    }

    public void setPaymentType(String paymentType) {
        this.paymentType = paymentType;
    }

    public String getOrderNum() {
        return orderNum;
    }

    public void setOrderNum(String orderNum) {
        this.orderNum = orderNum;
    }

   public BigDecimal getBeforeAccount() {
        return beforeAccount;
    }

    public void setBeforeAccount(BigDecimal beforeAccount) {
        this.beforeAccount = beforeAccount;
    }

    public BigDecimal getAfterAccount() {
        return afterAccount;
    }

    public void setAfterAccount(BigDecimal afterAccount) {
        this.afterAccount = afterAccount;
    }
}